project(lidar.convert CXX)

find_package(PCL COMPONENTS common io QUIET REQUIRED)
include_directories(${PCL_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ConvertToPcd.cpp)

target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17)
target_link_libraries(${PROJECT_NAME} PRIVATE lpc.message lpc.util)
target_link_libraries(${PROJECT_NAME} PUBLIC  pthread protobuf )
target_link_libraries(${PROJECT_NAME} PUBLIC  ${PCL_LIBRARIES} )

set_target_properties( ${PROJECT_NAME}
    PROPERTIES
    RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin"
)
add_executable(ConverToJson ConvertToJson.cpp)
target_compile_features(ConverToJson PRIVATE cxx_std_17)
target_link_libraries(ConverToJson PRIVATE lpc.message lpc.util)
target_link_libraries(ConverToJson PUBLIC  pthread protobuf )

set_target_properties(ConverToJson
    PROPERTIES
    RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin"
)

add_executable(PcdFileCheck PcdFileCheck.cpp)
target_compile_features(PcdFileCheck PRIVATE cxx_std_17)
target_link_libraries(PcdFileCheck PUBLIC  pthread   ${PCL_LIBRARIES} )
include_directories(${PCL_INCLUDE_DIRS})
set_target_properties(PcdFileCheck
    PROPERTIES
    RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin"
)



